﻿using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class BluetoothScanListener : AndroidJavaProxy
{
    Action<string> callback;
    public BluetoothScanListener(Action<string> callback) : base(AndroidBridge.packageName + ".BluetoothScanListener")
    {
        this.callback = callback;
    }

    public void OnGetName(string result)
    {
        //判断callback 是否为空  相当于if(!callback){callback.Invoke(result);}
        callback?.Invoke(result);
    }
}
